/*
 * Copyright (C) 2011 Kulabuhov Michael, Kemerovo, Russia.
 *
 * See the LICENSE file for terms of use.
 */
#include <Wt/WContainerWidget>
#include <Wt/WVBoxLayout>
#include "wpersephone.h"
#include "wpersephonetopline.h"
#include "wpersephoneheader.h"
#include "wpersephonebody.h"
#include "wpersephonefooter.h"

WPersephone::WPersephone(const WEnvironment& env)
  : WApplication(env)
{
  std::string outroot;
  this->readConfigurationProperty("outroot", outroot);
  messageResourceBundle().use(outroot + "/text");

  setTitle(WWidget::tr("site-title"));

  WVBoxLayout *layout = new WVBoxLayout(root());
  layout->setContentsMargins(0, 0, 0, 0);
  layout->setSpacing(0);
  layout->addWidget(new WPersephoneTopLine(), 0);
  layout->addWidget(new WPersephoneHeader(), 0);
  layout->addWidget(new WPersephoneBody(), 1);
  layout->addWidget(new WPersephoneFooter(), 0);
}
